Solving non-linear Horn clauses using a linear solver

نویسنده

  • Bishoksan Kafle
چکیده

Developing an efficient non-linear Horn clause solver is a challenging task since the solver has to reason about the tree structures rather than the linear ones as in a linear solver. In this paper we propose an incremental approach to solving a set of non-linear Horn clauses using a linear Horn clause solver. We achieve this by interleaving a program transformation and a linear solver. The program transformation is based on the notion of tree dimension, which we apply to trees corresponding to Horn clause derivations. The dimension of a tree is a measure of its non-linearity – for example a linear tree (whose nodes have at most one child) has dimension zero while a complete binary tree has dimension equal to its height. A given set of Horn clauses P can be transformed into a new set of clauses P≤k (whose derivation trees are the subset of P’s derivation trees with dimension at most k). We start by generating P≤k with k = 0, which is linear by definition, then pass it to a linear solver. If P≤k has a solution M, and is a solution to P then P has a solution M. If M is not a solution of P, we plugged M to P≤k+1 which again becomes linear and pass it to the solver and continue successively for increasing value of k until we find a solution to P or resources are exhausted. Experiment on some Horn clause verification benchmarks indicates that this is a promising approach for solving a set of non-linear Horn clauses using a linear solver. It indicates that many times a solution obtained for some under-approximation P≤k of P becomes a solution for P for a fairly small value of k.

برای دانلود متن کامل این مقاله و بیش از 32 میلیون مقاله دیگر ابتدا ثبت نام کنید

ثبت نام

اگر عضو سایت هستید لطفا وارد حساب کاربری خود شوید

منابع مشابه

Solving non-linear Horn clauses using a linear Horn clause solver

ion Refinement CHC P k = 0,S = / 0 Lin P′,S,k LS (safe, R↑P) R solution P? No S← R,k = k+1 S,R,k CA S← S|R,k (unsafe, R) S = S|R? Figure 7: Abstraction-refinement scheme for solving non-linear Horn clauses using a solver for linear Horn clauses. P′ is a set of linear CHC obtained by linearising the at-most-k-dimension underapproximation, P≤k, of P. The soundness of Algorithms 1 and 2 is capture...

متن کامل

Proving correctness of imperative programs by linearizing constrained Horn clauses

We present a method for verifying the correctness of imperative programs which is based on the automated transformation of their specifications. Given a program prog, we consider a partial correctness specification of the form {φ} prog {ψ}, where the assertions φ and ψ are predicates defined by a set Spec of possibly recursive Horn clauses with linear arithmetic (LA) constraints in their premis...

متن کامل

Solving Recursion-Free Horn Clauses over LI+UIF

Verification of programs with procedures, multi-threaded programs, and higher-order functional programs can be effectively automated using abstraction and refinement schemes that rely on spurious counterexamples for abstraction discovery. The analysis of counterexamples can be automated by a series of interpolation queries, or, alternatively, as a constraint solving query expressed by a set of ...

متن کامل

Mutually Exclusive Rules in LogicWeb

LogicWeb has traditionally lacked devices for expressing mutually exclusive clauses. We address this limitation by adopting choice-conjunctive clauses of the form D0&D1 where D0,D1 are Horn clauses and & is a linear logic connective. Solving a goal G using D0&D1 – pv(D0&D1, G) – has the following operational semantics: choose a successful one between pv(D0, G) and pv(D1, G). In other words, if ...

متن کامل

Resourceful Reachability as HORN-LA

The program verification tool SLAyer uses abstractions during analysis and relies on a solver for reachability to refine spurious counterexamples. In this context, we extract a reachability benchmark suite and evaluate methods for encoding reachability properties with heaps using Horn clauses over linear arithmetic. The benchmarks are particularly challenging and we describe and evaluate pre-pr...

متن کامل

ذخیره در منابع من


  با ذخیره ی این منبع در منابع من، دسترسی به آن را برای استفاده های بعدی آسان تر کنید

برای دانلود متن کامل این مقاله و بیش از 32 میلیون مقاله دیگر ابتدا ثبت نام کنید

ثبت نام

اگر عضو سایت هستید لطفا وارد حساب کاربری خود شوید

عنوان ژورنال:
  • CoRR

دوره abs/1511.06668  شماره 

صفحات  -

تاریخ انتشار 2015